//引入express
const express = require('express')

const router = require('./router')
//创建一个应用
const app = express()

app.use('/',router)

//是express监听 5000 端口的请求
const server = app.listen(5000, function () {
    const {address, port} = server.address()
    console.log('HTTP启动成功:http://%s:%s', address, port)
})
